<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.w3.org/1999/xhtml">
<head>
    <meta charset="UTF-8">
    <title>比赛</title>
</head>
<body>
<h1 th:text="${contest.contest.title}"></h1>
<h3 th:text="'结束时间'+${endtime}"></h3>
<p><a th:href="@{'/contest/'+${contest.contest.contestid} + '/ranklist' }">排行榜</a></p>
<h2>题目列表：</h2>
<table th:with="count = 1" border="1">
    <tr th:each="problem:${contest.problems}">
        <td ><a target="_blank" th:text="${problem.title}" th:href="@{'/contest/'+ ${contest.contest.contestid} +'/problem/'+ ${problem.problemid} }"></a></td>
        <td><button th:onclick="@{'window.open(\''+'/api/contest/'+${contest.contest.contestid}+'/problem/'+${problemStat.count}+'/submit'+'\')'}">提交</button></td>
    </tr>
</table>
</body>
</html>